
import request from '@/utils/request'
// 抽取出来方便后面使用
const apiUrl = '/admin/system/sysMenu'


// 查询全部菜单
export const showAllMenu=()=>{
  return request({
    url: `${apiUrl}/showAll`,
    method: 'get',
  })
}
// 新增菜单
export const addMenu=(data)=>{
  return request({
    url: `${apiUrl}/add`,
    method: 'post',
    data
  })
}
// 更新菜单
export const updateMenu=(data)=>{
  return request({
    url: `${apiUrl}/update`,
    method: 'put',
    data
  })
}

// 删除菜单
export const removeById=(id)=>{
  return request({
    url: `${apiUrl}/removeById/${id}`,
    method: 'delete'
  })
}


